# 写django项目的时候,匹配文件名的后缀名
import re

str1 = "test.jpg"

result = re.search('(\.)[a-z]*',str1)
result = result.group()
result = result[1:]
print(result)

str2 = "b'group1/M00/00/00/rBMgZGDi-66Afs6VAAAmv27pX4k1068552'"

# result2 = re.search("^(b\\').*(\\')$",str2)

# print(result2.group())
str2 = str2[2:]
str2 = str2.replace("'","")
print(str2)